<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><?php echo F('web_page_title');?></title>
<?php TPL::plugin('include/css_link');?>
<?php TPL::plugin('include/js_link');?>
</head>
<body id="follow">
	<div id="wrap">
		<div class="wrap-in">
			<?php TPL::plugin('include/header');?>
			<div id="container">
				<div class="extra">
					<!-- 站点导航 开始 -->
					<?php Xpipe::pagelet('common.siteNav');?>
					<!-- 站点导航 结束 -->
				</div>
				<div class="content">
					<div class="main-wrap">
						<div class="main">
                        	<div class="main-bd">
                        	<div class="user-recommed">
    <div class="title-box">
        <h3>折扣微博搜索结果</h3>
    </div>
	<div class="user-list-wrap">
<?php
	
	//关注列表
	$uid = USER::uid();
	$i = 1;
	foreach ($data as $star) {
		$is_odd = ($i & 1) ? true : false;
		$star['uid'] = isset($star['uid']) ? $star['uid'] : $star['id'];
		$nick = isset($star['screen_name']) ? F('escape', $star['screen_name']) : F('escape', $star['nickname']);
		$user_img = isset($star['profile_image_url']) ? F('profile_image_url', $star['profile_image_url']) : F('profile_image_url', $star['uid']);
		if(isset($star['remark'])){
			$remark = F('escape', $star['remark']);
		}elseif(isset($star['description'])){
			$remark = F('escape', $star['description']);
		}else{
			$remark = '';
		}
		
		$profile_url = URL('ta', array('id' => $star['uid']));
?>
		<div class="user-item" rel="u:<?php echo $star['uid'];?>">
			<div class="user-pic">
				<a href="<?php echo $profile_url;?>"><img src="<?php echo $user_img;?>" alt="<?php echo $nick. L('modules_component_component_2_headTitle');?>" /></a>
			</div>

			<?php if (!$star['following']):?>
                <a class="addfollow-btn" rel="e:fl,t:1" href="#"><span class="plus">+</span><?php LO('modules_component_component_2_follow');?></a>
			<?php else:?>
				<span class="followed-btn"><?php LO('modules_component_component_2_followed');?></span>
			<?php endif;?>

			<div class="user-info">
				<a class="u-name" href="<?php echo $profile_url;?>"><?php echo $nick; echo F('verified', $star); ?></a>
				<?php if (isset($star['location']) && isset($star['gender'])) {?>
				<span class="<?php echo $star['gender'] == 'f' ? 'ico-female' : 'ico-male'; ?>"><?php echo $star['location']; ?></span>
				<?php }?>
		        <p><?php echo mb_strwidth($remark, 'UTF-8') > 30 ? mb_substr($remark, 0, 13, 'UTF-8') . '...' : $remark; ?></p>
			</div>
        </div>
<?php
		$i++;
	}
?>
	<?php if (count($rs) %2 !== 0) {?>
		<div class="user-item"></div>
	<?php }?>

	</div>
</div>
								
							</div>
                        </div>
						<div class="aside">
							<!-- 用户信息 开始-->
							<?php Xpipe::pagelet('common.userPreview');?>
							<!-- 用户标签 开始-->
							<?php Xpipe::pagelet('common.userTag');?>
							<?php Xpipe::pagelet('common.sideComponents', array('type'=>2) );?>
						<?php echo F('show_ad', 'sidebar', '');?>
						</div>
					</div>
				</div>
			</div>
			<!-- 尾部 开始 -->
            <?php TPL::module('footer');?>
			<!-- 尾部 结束 -->
		</div>
	</div>
	<?php TPL::module('gotop');?>
</body>
</html>
